<template>
  <div>
      <!-- 二级路由出口 -->
      <!-- <p>我是二级路由</p> -->
      <router-view></router-view>
      <!-- 底部栏 -->
      <!-- route 页面切换的开关 -->
      <van-tabbar v-model="active" route>   
        <van-tabbar-item to="/home" icon="home-o">首页</van-tabbar-item>
        <van-tabbar-item to="/qa" icon="search">问答</van-tabbar-item>
        <van-tabbar-item to="/movie" icon="friends-o">视频</van-tabbar-item>
        <van-tabbar-item to="/user" icon="setting-o">用户</van-tabbar-item>
      </van-tabbar>
      
  </div>
</template>

<script>
export default {
    name:'layout',
    data() {
    return {
      active: 0,
    };
  },
}
</script>

<style>

</style>